package com.greensam.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Builder;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import java.io.Serial;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @Author: Machengrui
 * @Date: 2024/9/23 16:39
 */
@Data
@Builder
@Schema(title = "base_user_info对象",description = "用户信息表")
public class BaseUserInfo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "用户id")
    @TableId(value = "uid", type = IdType.AUTO)
    private Long uid;

    @Schema(description = "登陆账号")
    @NotBlank(message = "账号不能为空")
    private String account;

    @Schema(description = "登陆密码")
    @NotBlank(message = "密码不能为空")
    private String password;

    @Schema(description = "用户名")
    @NotBlank(message = "用户名不能为空")
    private String userName;

    @Schema(description = "检索码")
    private String code;

    @Schema(description = "用户性别：0-女 1-男")
    @NotBlank(message = "性别不能为空")
    private Integer sex;

    @Schema(description = "手机号码")
    private String mobile;

    @Schema(description = "邮箱")
    private String email;

    @Schema(description = "身份证")
    private String idCard;

    @Schema(description = "创建时间")
    private LocalDateTime createTime;

    @Schema(description = "更新时间")
    private LocalDateTime updateTime;

    @Schema(description = "状态标志：0-停用 1-启用")
    private Integer state;

    @Schema(description = "备注")
    private String remark;

}
